Imports System.IO

Public Class ExportView

    Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
        Me.DialogResult = Windows.Forms.DialogResult.Cancel
    End Sub

    Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
        Dim fs As New SaveFileDialog
        fs.Filter = "Plain Text|*.txt|Comma Separated|*.csv|XML|*.xml|All Files|*"
        If fs.ShowDialog = Windows.Forms.DialogResult.OK Then
            File.WriteAllText(fs.FileName, Me.OutputField.Text)
            MsgBox("File Saved")
        End If
    End Sub

    Public Property OutputText() As String
        Get
            Return Me.OutputField.Text
        End Get
        Set(ByVal Value As String)
            Me.OutputField.Text = Value
        End Set
    End Property


End Class